#!/usr/bin/env bash

# Key considerations for algorithm "RSA" ≥ 2048-bit
openssl genrsa -out keys/server.key 2048

# Key considerations for algorithm "ECDSA" ≥ secp384r1
# List ECDSA the supported curves (openssl ecparam -list_curves)
openssl ecparam -genkey -name secp384r1 -out keys/server.key

#openssl req -new -x509 -sha256 -key keys/server.key -out keys/server.pem -days 3650

openssl req -new -x509 -sha256 -key keys/server.key -subj "/C=CN/ST=GD/L=SZ/O=vihoo/OU=dev/CN=localhost/emailAddress=1577121881@qq.com"  -out keys/server.pem -days 3650

